/*
 *
 *    Copyright (c) 2022 Project CHIP Authors
 *
 *    Licensed under the Apache License, Version 2.0 (the "License");
 *    you may not use this file except in compliance with the License.
 *    You may obtain a copy of the License at
 *
 *        http://www.apache.org/licenses/LICENSE-2.0
 *
 *    Unless required by applicable law or agreed to in writing, software
 *    distributed under the License is distributed on an "AS IS" BASIS,
 *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 *    See the License for the specific language governing permissions and
 *    limitations under the License.
 */

// THIS FILE IS GENERATED BY ZAP
// This file is generated from clusters-Attributes.h.zapt

#pragma once

#include <app/ConcreteAttributePath.h>
#include <app/data-model/DecodableList.h>
#include <app/data-model/List.h>
#include <app/data-model/Nullable.h>
#include <app/util/basic-types.h>
#include <lib/core/TLV.h>
#include <lib/support/BitMask.h>

#include <clusters/shared/Attributes.h>
#include <clusters/shared/Enums.h>
#include <clusters/shared/Structs.h>

#include <clusters/LevelControl/AttributeIds.h>
#include <clusters/LevelControl/ClusterId.h>
#include <clusters/LevelControl/Enums.h>
#include <clusters/LevelControl/Structs.h>

namespace chip
{
namespace app
{
	namespace Clusters
	{
		namespace LevelControl
		{
			namespace Attributes
			{

				namespace CurrentLevel
				{
					struct TypeInfo {
						using Type = chip::app::DataModel::Nullable<uint8_t>;
						using DecodableType = chip::app::DataModel::Nullable<uint8_t>;
						using DecodableArgType =
							const chip::app::DataModel::Nullable<uint8_t> &;

						static constexpr ClusterId GetClusterId()
						{
							return Clusters::LevelControl::Id;
						}
						static constexpr AttributeId GetAttributeId()
						{
							return Attributes::CurrentLevel::Id;
						}
						static constexpr bool MustUseTimedWrite() { return false; }
					};
				} // namespace CurrentLevel
				namespace RemainingTime
				{
					struct TypeInfo {
						using Type = uint16_t;
						using DecodableType = uint16_t;
						using DecodableArgType = uint16_t;

						static constexpr ClusterId GetClusterId()
						{
							return Clusters::LevelControl::Id;
						}
						static constexpr AttributeId GetAttributeId()
						{
							return Attributes::RemainingTime::Id;
						}
						static constexpr bool MustUseTimedWrite() { return false; }
					};
				} // namespace RemainingTime
				namespace MinLevel
				{
					struct TypeInfo {
						using Type = uint8_t;
						using DecodableType = uint8_t;
						using DecodableArgType = uint8_t;

						static constexpr ClusterId GetClusterId()
						{
							return Clusters::LevelControl::Id;
						}
						static constexpr AttributeId GetAttributeId()
						{
							return Attributes::MinLevel::Id;
						}
						static constexpr bool MustUseTimedWrite() { return false; }
					};
				} // namespace MinLevel
				namespace MaxLevel
				{
					struct TypeInfo {
						using Type = uint8_t;
						using DecodableType = uint8_t;
						using DecodableArgType = uint8_t;

						static constexpr ClusterId GetClusterId()
						{
							return Clusters::LevelControl::Id;
						}
						static constexpr AttributeId GetAttributeId()
						{
							return Attributes::MaxLevel::Id;
						}
						static constexpr bool MustUseTimedWrite() { return false; }
					};
				} // namespace MaxLevel
				namespace CurrentFrequency
				{
					struct TypeInfo {
						using Type = uint16_t;
						using DecodableType = uint16_t;
						using DecodableArgType = uint16_t;

						static constexpr ClusterId GetClusterId()
						{
							return Clusters::LevelControl::Id;
						}
						static constexpr AttributeId GetAttributeId()
						{
							return Attributes::CurrentFrequency::Id;
						}
						static constexpr bool MustUseTimedWrite() { return false; }
					};
				} // namespace CurrentFrequency
				namespace MinFrequency
				{
					struct TypeInfo {
						using Type = uint16_t;
						using DecodableType = uint16_t;
						using DecodableArgType = uint16_t;

						static constexpr ClusterId GetClusterId()
						{
							return Clusters::LevelControl::Id;
						}
						static constexpr AttributeId GetAttributeId()
						{
							return Attributes::MinFrequency::Id;
						}
						static constexpr bool MustUseTimedWrite() { return false; }
					};
				} // namespace MinFrequency
				namespace MaxFrequency
				{
					struct TypeInfo {
						using Type = uint16_t;
						using DecodableType = uint16_t;
						using DecodableArgType = uint16_t;

						static constexpr ClusterId GetClusterId()
						{
							return Clusters::LevelControl::Id;
						}
						static constexpr AttributeId GetAttributeId()
						{
							return Attributes::MaxFrequency::Id;
						}
						static constexpr bool MustUseTimedWrite() { return false; }
					};
				} // namespace MaxFrequency
				namespace Options
				{
					struct TypeInfo {
						using Type =
							chip::BitMask<chip::app::Clusters::LevelControl::OptionsBitmap>;
						using DecodableType =
							chip::BitMask<chip::app::Clusters::LevelControl::OptionsBitmap>;
						using DecodableArgType =
							chip::BitMask<chip::app::Clusters::LevelControl::OptionsBitmap>;

						static constexpr ClusterId GetClusterId()
						{
							return Clusters::LevelControl::Id;
						}
						static constexpr AttributeId GetAttributeId()
						{
							return Attributes::Options::Id;
						}
						static constexpr bool MustUseTimedWrite() { return false; }
					};
				} // namespace Options
				namespace OnOffTransitionTime
				{
					struct TypeInfo {
						using Type = uint16_t;
						using DecodableType = uint16_t;
						using DecodableArgType = uint16_t;

						static constexpr ClusterId GetClusterId()
						{
							return Clusters::LevelControl::Id;
						}
						static constexpr AttributeId GetAttributeId()
						{
							return Attributes::OnOffTransitionTime::Id;
						}
						static constexpr bool MustUseTimedWrite() { return false; }
					};
				} // namespace OnOffTransitionTime
				namespace OnLevel
				{
					struct TypeInfo {
						using Type = chip::app::DataModel::Nullable<uint8_t>;
						using DecodableType = chip::app::DataModel::Nullable<uint8_t>;
						using DecodableArgType =
							const chip::app::DataModel::Nullable<uint8_t> &;

						static constexpr ClusterId GetClusterId()
						{
							return Clusters::LevelControl::Id;
						}
						static constexpr AttributeId GetAttributeId()
						{
							return Attributes::OnLevel::Id;
						}
						static constexpr bool MustUseTimedWrite() { return false; }
					};
				} // namespace OnLevel
				namespace OnTransitionTime
				{
					struct TypeInfo {
						using Type = chip::app::DataModel::Nullable<uint16_t>;
						using DecodableType = chip::app::DataModel::Nullable<uint16_t>;
						using DecodableArgType =
							const chip::app::DataModel::Nullable<uint16_t> &;

						static constexpr ClusterId GetClusterId()
						{
							return Clusters::LevelControl::Id;
						}
						static constexpr AttributeId GetAttributeId()
						{
							return Attributes::OnTransitionTime::Id;
						}
						static constexpr bool MustUseTimedWrite() { return false; }
					};
				} // namespace OnTransitionTime
				namespace OffTransitionTime
				{
					struct TypeInfo {
						using Type = chip::app::DataModel::Nullable<uint16_t>;
						using DecodableType = chip::app::DataModel::Nullable<uint16_t>;
						using DecodableArgType =
							const chip::app::DataModel::Nullable<uint16_t> &;

						static constexpr ClusterId GetClusterId()
						{
							return Clusters::LevelControl::Id;
						}
						static constexpr AttributeId GetAttributeId()
						{
							return Attributes::OffTransitionTime::Id;
						}
						static constexpr bool MustUseTimedWrite() { return false; }
					};
				} // namespace OffTransitionTime
				namespace DefaultMoveRate
				{
					struct TypeInfo {
						using Type = chip::app::DataModel::Nullable<uint8_t>;
						using DecodableType = chip::app::DataModel::Nullable<uint8_t>;
						using DecodableArgType =
							const chip::app::DataModel::Nullable<uint8_t> &;

						static constexpr ClusterId GetClusterId()
						{
							return Clusters::LevelControl::Id;
						}
						static constexpr AttributeId GetAttributeId()
						{
							return Attributes::DefaultMoveRate::Id;
						}
						static constexpr bool MustUseTimedWrite() { return false; }
					};
				} // namespace DefaultMoveRate
				namespace StartUpCurrentLevel
				{
					struct TypeInfo {
						using Type = chip::app::DataModel::Nullable<uint8_t>;
						using DecodableType = chip::app::DataModel::Nullable<uint8_t>;
						using DecodableArgType =
							const chip::app::DataModel::Nullable<uint8_t> &;

						static constexpr ClusterId GetClusterId()
						{
							return Clusters::LevelControl::Id;
						}
						static constexpr AttributeId GetAttributeId()
						{
							return Attributes::StartUpCurrentLevel::Id;
						}
						static constexpr bool MustUseTimedWrite() { return false; }
					};
				} // namespace StartUpCurrentLevel
				namespace GeneratedCommandList
				{
					struct TypeInfo
						: public Clusters::Globals::Attributes::GeneratedCommandList::TypeInfo {
						static constexpr ClusterId GetClusterId()
						{
							return Clusters::LevelControl::Id;
						}
					};
				} // namespace GeneratedCommandList
				namespace AcceptedCommandList
				{
					struct TypeInfo
						: public Clusters::Globals::Attributes::AcceptedCommandList::TypeInfo {
						static constexpr ClusterId GetClusterId()
						{
							return Clusters::LevelControl::Id;
						}
					};
				} // namespace AcceptedCommandList
				namespace AttributeList
				{
					struct TypeInfo
						: public Clusters::Globals::Attributes::AttributeList::TypeInfo {
						static constexpr ClusterId GetClusterId()
						{
							return Clusters::LevelControl::Id;
						}
					};
				} // namespace AttributeList
				namespace FeatureMap
				{
					struct TypeInfo : public Clusters::Globals::Attributes::FeatureMap::TypeInfo {
						static constexpr ClusterId GetClusterId()
						{
							return Clusters::LevelControl::Id;
						}
					};
				} // namespace FeatureMap
				namespace ClusterRevision
				{
					struct TypeInfo
						: public Clusters::Globals::Attributes::ClusterRevision::TypeInfo {
						static constexpr ClusterId GetClusterId()
						{
							return Clusters::LevelControl::Id;
						}
					};
				} // namespace ClusterRevision

				struct TypeInfo {
					struct DecodableType {
						static constexpr ClusterId GetClusterId()
						{
							return Clusters::LevelControl::Id;
						}

						CHIP_ERROR Decode(TLV::TLVReader &reader,
								  const ConcreteAttributePath &path);

						Attributes::CurrentLevel::TypeInfo::DecodableType currentLevel;
						Attributes::RemainingTime::TypeInfo::DecodableType remainingTime =
							static_cast<uint16_t>(0);
						Attributes::MinLevel::TypeInfo::DecodableType minLevel =
							static_cast<uint8_t>(0);
						Attributes::MaxLevel::TypeInfo::DecodableType maxLevel =
							static_cast<uint8_t>(0);
						Attributes::CurrentFrequency::TypeInfo::DecodableType currentFrequency =
							static_cast<uint16_t>(0);
						Attributes::MinFrequency::TypeInfo::DecodableType minFrequency =
							static_cast<uint16_t>(0);
						Attributes::MaxFrequency::TypeInfo::DecodableType maxFrequency =
							static_cast<uint16_t>(0);
						Attributes::Options::TypeInfo::DecodableType options = static_cast<
							chip::BitMask<chip::app::Clusters::LevelControl::OptionsBitmap>>(
							0);
						Attributes::OnOffTransitionTime::TypeInfo::DecodableType
							onOffTransitionTime = static_cast<uint16_t>(0);
						Attributes::OnLevel::TypeInfo::DecodableType onLevel;
						Attributes::OnTransitionTime::TypeInfo::DecodableType onTransitionTime;
						Attributes::OffTransitionTime::TypeInfo::DecodableType offTransitionTime;
						Attributes::DefaultMoveRate::TypeInfo::DecodableType defaultMoveRate;
						Attributes::StartUpCurrentLevel::TypeInfo::DecodableType
							startUpCurrentLevel;
						Attributes::GeneratedCommandList::TypeInfo::DecodableType
							generatedCommandList;
						Attributes::AcceptedCommandList::TypeInfo::DecodableType
							acceptedCommandList;
						Attributes::AttributeList::TypeInfo::DecodableType attributeList;
						Attributes::FeatureMap::TypeInfo::DecodableType featureMap =
							static_cast<uint32_t>(0);
						Attributes::ClusterRevision::TypeInfo::DecodableType clusterRevision =
							static_cast<uint16_t>(0);
					};
				};
			} // namespace Attributes
		} // namespace LevelControl
	} // namespace Clusters
} // namespace app
} // namespace chip
